Kanzi 3.9.10
kanzi::ApplicationProperties Struct Reference

Configurable application properties. More...

#include <kanzi/core.ui/application/application_properties.hpp>

Classes

class  FontEngineHasher
 Class that provides the hash operator for the FontEngine enumeration. More...
 
struct  ImageLoadParameters
 Parameters that Kanzi passes to third-party image libraries when loading image files. More...
 
struct  Slog2Config
 User configurable parameters for slogger2. Default values are set in the ApplicationProperties constructor. More...
 

Public Types

enum class  FontEngine { None , FreeType , IType }
 Specifies the font engine to load at application startup to render the text in your application. More...
 
enum  HandleGPUResources { NoHandling , Invalidate , Destroy }
 Sets how an application handles GPU resources in the paused state. More...
 
enum  PerformanceInfoLevel { PerformanceInfoLevelDisabled , PerformanceInfoLevelFPS , PerformanceInfoLevelFull }
 Performance info level. More...
 

Public Member Functions

 ApplicationProperties ()
 Constructor.
 

Public Attributes

bool applicationIdleStateEnabled
 When an application is in the idle state, if there are no changes in the node tree and rendering is not necessary, the application main loop waits for events, such as input.
 
string binaryName
 Path to either the binary config file listing all .kzb files that are loaded to project, or a path to a single .kzb file.
 
NativeDesktopProperties defaultDesktopProperties
 Default properties for desktop.
 
EventSourceProperties defaultEventSourceProperties
 Default properties for the event sources.
 
KzsSurfaceProperties defaultSurfaceProperties
 Default properties for the surfaces of the windows.
 
NativeWindowProperties defaultWindowProperties
 Default properties for application windows.
 
chrono::nanoseconds deploymentQueueBudget
 The time allocated per frame for processing the deployment queue.
 
bool extensionOutputEnabled
 Indicates whether the list of graphics related extensions printed when launching the application.
 
FontEngine fontEngine
 The font engine to load at application startup.
 
unordered_map< FontEngine, string, FontEngineHasherfontEngineDictionaryUrls
 Optional lists of resource URLs that point to dictionaries that the font engines use.
 
int frameRateLimit
 Framerate limit as frames per second.
 
unsigned int glyphCacheHeight
 Height of the textures created for glyph caches.
 
unsigned int glyphCacheWidth
 Width of the textures created for glyph caches.
 
bool graphicsLoggingEnabled
 Indicates whether graphics API calls should be logged, useful for debugging.
 
HandleGPUResources handleGPUResources
 Handling of GPU resources when the application is paused.
 
ImageLoadParameters imageLoad
 Parameters that Kanzi passes to third-party image libraries when loading image files.
 
bool informationOutputEnabled
 Indicates whether the list of graphics related information printed when launching the application, useful for debugging.
 
unsigned int loadingThreadCount
 The number of background threads that are used to load resources.
 
optional< size_t > mainLoopProfilingSampleBufferCount
 Main loop profiling sample buffer count.
 
unsigned int maxPendingResources
 The maximum number of resources that can be processed by the loading threads at the same time.
 
MmapMode mmapMode
 The chosen memory mapping mode.
 
vector< string > moduleNames
 List of modules to load.
 
Renderer::RendererSettings::MultisamplePreference multisamplePreference
 Multisample preference setting.
 
PerformanceInfoLevel performanceInfoLevel
 Performance info display level.
 
PerformanceInfoProperties performanceInfoProperties
 Properties of the performance info display.
 
string profilingCategoryFilter
 Profiling category filter.
 
bool propertyOutputEnabled
 Indicates whether the list of graphics related properties printed when launching the application, useful for debugging.
 
bool shaderBinaryCacheCollisionCheck
 Indicates whether to check for hash collisions in shader binaries.
 
string shaderBinaryCacheDirectory
 Shader binary cache directory.
 
bool shaderBinaryCacheEnabled
 Indicates whether to cache shader binaries.
 
bool shaderBinaryCacheReadOnly
 Indicates whether the cache is read-only.
 
Slog2Config slog2Config
 User configurable options for slogger2 (QNX).
 
SystemConfiguration systemConfiguration
 Platform-specific configuration parameters.
 

Detailed Description

Configurable application properties.

Member Enumeration Documentation

◆ PerformanceInfoLevel

Performance info level.

Enumerator
PerformanceInfoLevelDisabled 

Disabled.

PerformanceInfoLevelFPS 

Show FPS only.

PerformanceInfoLevelFull 

Full info.

◆ HandleGPUResources

Sets how an application handles GPU resources in the paused state.

Since
Kanzi 3.9.7
Enumerator
NoHandling 

Do nothing.

Invalidate 

Invalidate all GPU resources.

Destroy 

Destroy all GPU resources.

◆ FontEngine

Specifies the font engine to load at application startup to render the text in your application.

In a static build, you must statically link to the application the font engine that you want to load. In a dynamic build, Kanzi loads the font engine library that you request.

Enumerator
None 

Do not load a font engine.

When you do not load a font engine, Kanzi does not render the text in your application.

FreeType 

Load the FreeType font engine.

IType 

Load the iType font engine.

Constructor & Destructor Documentation

◆ ApplicationProperties()

kanzi::ApplicationProperties::ApplicationProperties ( )
explicit

Constructor.

Member Data Documentation

◆ defaultWindowProperties

NativeWindowProperties kanzi::ApplicationProperties::defaultWindowProperties

Default properties for application windows.

◆ defaultSurfaceProperties

KzsSurfaceProperties kanzi::ApplicationProperties::defaultSurfaceProperties

Default properties for the surfaces of the windows.

◆ defaultDesktopProperties

NativeDesktopProperties kanzi::ApplicationProperties::defaultDesktopProperties

Default properties for desktop.

Since
Kanzi 3.9.7

◆ defaultEventSourceProperties

EventSourceProperties kanzi::ApplicationProperties::defaultEventSourceProperties

Default properties for the event sources.

◆ imageLoad

ImageLoadParameters kanzi::ApplicationProperties::imageLoad

Parameters that Kanzi passes to third-party image libraries when loading image files.

◆ binaryName

string kanzi::ApplicationProperties::binaryName

Path to either the binary config file listing all .kzb files that are loaded to project, or a path to a single .kzb file.

◆ moduleNames

vector<string> kanzi::ApplicationProperties::moduleNames

List of modules to load.

◆ frameRateLimit

int kanzi::ApplicationProperties::frameRateLimit

Framerate limit as frames per second.

Set to 0 to disable limiting the framerate altogether.

◆ loadingThreadCount

unsigned int kanzi::ApplicationProperties::loadingThreadCount

The number of background threads that are used to load resources.

By default set to min(number of cores - 1, 3). Set to 0 to disable multithreaded loading and load everything in the main thread.

◆ maxPendingResources

unsigned int kanzi::ApplicationProperties::maxPendingResources

The maximum number of resources that can be processed by the loading threads at the same time.

The higher number can make the loading faster, but increases the peak memory usage during loading as more resources can be loaded to the memory before they are deployed to the GPU. If set to 0 (which is the default value), the value is set to the number of threads + 1.

◆ deploymentQueueBudget

chrono::nanoseconds kanzi::ApplicationProperties::deploymentQueueBudget

The time allocated per frame for processing the deployment queue.

If the deployment queue is empty, no time will be spent. If set to 0 (which is the default value, a single item from the deployment queue will be processed each frame.

◆ glyphCacheWidth

unsigned int kanzi::ApplicationProperties::glyphCacheWidth

Width of the textures created for glyph caches.

◆ glyphCacheHeight

unsigned int kanzi::ApplicationProperties::glyphCacheHeight

Height of the textures created for glyph caches.

◆ performanceInfoLevel

PerformanceInfoLevel kanzi::ApplicationProperties::performanceInfoLevel

Performance info display level.

◆ performanceInfoProperties

PerformanceInfoProperties kanzi::ApplicationProperties::performanceInfoProperties

Properties of the performance info display.

◆ extensionOutputEnabled

bool kanzi::ApplicationProperties::extensionOutputEnabled

Indicates whether the list of graphics related extensions printed when launching the application.

It is useful for debugging which extensions are supported by platform.

◆ propertyOutputEnabled

bool kanzi::ApplicationProperties::propertyOutputEnabled

Indicates whether the list of graphics related properties printed when launching the application, useful for debugging.

◆ informationOutputEnabled

bool kanzi::ApplicationProperties::informationOutputEnabled

Indicates whether the list of graphics related information printed when launching the application, useful for debugging.

◆ graphicsLoggingEnabled

bool kanzi::ApplicationProperties::graphicsLoggingEnabled

Indicates whether graphics API calls should be logged, useful for debugging.

◆ profilingCategoryFilter

string kanzi::ApplicationProperties::profilingCategoryFilter

Profiling category filter.

Use profiling category filters to set the state for profiling categories:

  • "off" disables performance profiling.
  • "on" enables performance profiling.

Each filter token consists of category name and state separated with the equal sign (=). Use semicolons (;) to separate multiple filter tokens. For example:

"category1=on;category2=off"

To apply a setting for all profiling categories, use the asterisk (*). For example, to enable all categories:

"*=on"

The filter is evaluated from left to right, meaning that each setting overrides previous ones. For example, to disable all categories except category1:

"*=off;category1=on"

To set the same state for multiple categories, separate the categories with pipes (|). For example, to enable category1 and category2:

"category1|category2=on"

◆ applicationIdleStateEnabled

bool kanzi::ApplicationProperties::applicationIdleStateEnabled

When an application is in the idle state, if there are no changes in the node tree and rendering is not necessary, the application main loop waits for events, such as input.

When you disable the application idle state, Kanzi extends this wait only until the next frame. When you enable the application idle state (the default setting), Kanzi waits until the application receives an event. Other threads may also post tasks to interrupt idle state.

◆ mainLoopProfilingSampleBufferCount

optional<size_t> kanzi::ApplicationProperties::mainLoopProfilingSampleBufferCount

Main loop profiling sample buffer count.

Optional override for the default size of sample buffers used by main loop profiling

◆ fontEngine

FontEngine kanzi::ApplicationProperties::fontEngine

The font engine to load at application startup.

The default value is FreeType.

◆ fontEngineDictionaryUrls

unordered_map<FontEngine, string, FontEngineHasher> kanzi::ApplicationProperties::fontEngineDictionaryUrls

Optional lists of resource URLs that point to dictionaries that the font engines use.

Separate the resource URLs with a semicolon.

Since
Kanzi 3.9.4

◆ mmapMode

MmapMode kanzi::ApplicationProperties::mmapMode

The chosen memory mapping mode.

◆ slog2Config

Slog2Config kanzi::ApplicationProperties::slog2Config

User configurable options for slogger2 (QNX).

◆ systemConfiguration

SystemConfiguration kanzi::ApplicationProperties::systemConfiguration

Platform-specific configuration parameters.

See your platform documentation for details.

◆ multisamplePreference

Renderer::RendererSettings::MultisamplePreference kanzi::ApplicationProperties::multisamplePreference

Multisample preference setting.

◆ shaderBinaryCacheEnabled

bool kanzi::ApplicationProperties::shaderBinaryCacheEnabled

Indicates whether to cache shader binaries.

By default, the application does not cache shader binaries.

Since
Kanzi 3.9.8

◆ shaderBinaryCacheReadOnly

bool kanzi::ApplicationProperties::shaderBinaryCacheReadOnly

Indicates whether the cache is read-only.

By default, Kanzi updates the cache.

Since
Kanzi 3.9.8

◆ shaderBinaryCacheCollisionCheck

bool kanzi::ApplicationProperties::shaderBinaryCacheCollisionCheck

Indicates whether to check for hash collisions in shader binaries.

By default, the application does not check for hash collisions.

Since
Kanzi 3.9.8

◆ shaderBinaryCacheDirectory

string kanzi::ApplicationProperties::shaderBinaryCacheDirectory

Shader binary cache directory.

Since
Kanzi 3.9.8

◆ handleGPUResources

HandleGPUResources kanzi::ApplicationProperties::handleGPUResources

Handling of GPU resources when the application is paused.

The default value is:

Since
Kanzi 3.9.7

The documentation for this struct was generated from the following file: